﻿@model ebook.Models.RegisterModel
@{
    ViewBag.Title = "Register";
}

<hgroup class="title">
    <h1>@ViewBag.Title.</h1>
    <h2>Create a new account.</h2>
</hgroup>

@using (Html.BeginForm())
{
    @Html.AntiForgeryToken()
    @Html.ValidationSummary()
    
    <fieldset>
        <legend>Registration Form</legend>
        <ol>
            <li>
                @Html.LabelFor(m => m.UserName)
                @Html.TextBoxFor(m => m.UserName)
            </li>
            <li>
                @Html.LabelFor(m => m.Password)
                @Html.PasswordFor(m => m.Password)
            </li>
            <li>
                @Html.LabelFor(m => m.ConfirmPassword)
                @Html.PasswordFor(m => m.ConfirmPassword)
            </li>
            <li>
                <div class="editor-label">
                    @Html.LabelFor(model => model.Captcha)
                    <a href="@Url.Action("Index","Captcha")">
                        <img alt="Captcha" src="@Url.Action("CaptchaImage", "Captcha")" style="" />
                    </a>
                </div>
                <div class="editor-field">
                    @Html.EditorFor(model => model.Captcha)
                    @Html.ValidationMessageFor(model => model.Captcha)
                </div>
            </li>
        </ol>

        <input type="submit" value="Register" />
    </fieldset>
}

@section Scripts {
    @Scripts.Render("~/bundles/jqueryval")
}
